package cn.touna.jss.modules.credit.service;

import cn.touna.jss.common.entity.CreditQueryRequest;
import cn.touna.jss.modules.credit.entity.CreditQueryHistoryEntity;
import cn.touna.jss.modules.credit.entity.CreditQueryHistorySimplifiedEntity;
import cn.touna.jss.modules.credit.entity.CreditRecordRef;
import cn.touna.risk.api.domain.Response;

import java.util.Date;
import java.util.List;

/**
 * 资信查询service
 * Created by wuwc on 2017/07/28.
 */
public interface CreditQueryService {


    /**
     * 保存查询记录
     *
     * @param historyEntity
     */
    void saveQueryHistory(CreditQueryRequest request, Response creditQueryResponse) throws Exception;

    /**
     * 保存rowkey
     *
     * @param recordRef
     */
    void saveCreditRef(CreditRecordRef recordRef);


    /**
     * 根据昵称类型查询昵称
     *
     * @param type
     * @return
     */
    List<String> selectNiceList(String type);

    List<CreditQueryHistorySimplifiedEntity> queryCreditHistorySimplified(CreditQueryHistoryEntity entity);

    List<CreditQueryHistoryEntity> selectByCrNo(String crNo);

    List<CreditQueryHistoryEntity> selectByMethod(String serviceName, String methodName, Date begin, Date end);

}
